# -*- coding: utf-8 -*-

from douban_client import DoubanClient

KEY = '09ebbaa767412e021dc32ff635c38a06'
SECRET = 'c89124c9b78c487c'
CALLBACK = 'http://www.zhangpanbin.com'


SCOPE = 'douban_basic_common,community_basic_user,community_advanced_doumail_w,community_advanced_doumail_r,community_advanced_photo,community_basic_photo'
client = DoubanClient(KEY, SECRET, CALLBACK, SCOPE)

client.auth_with_token('45886bf9bf3aa810d09943ed3daff830')

"""
print client.authorize_url
code = raw_input('Enter the verification code:') 
client.auth_with_code(code) 
print client.client.token
"""
print client.user.me

"""
client.doumail.new('测试title','test','50773728')
print client.album.list('64328329'
print client.user.get('sixteen16')
print client.album.photos('55576502')
"""

print client.album.list('64328329')
